package com.service.admin.product.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.service.admin.product.controller.rep.HashRateComboItemRep;
import com.service.core.rest.response.CommonPageRep;
import com.service.dao.enums.CommonStatusEnums;
import com.service.dao.enums.HrComboEnum;
import com.service.dao.model.ProductHrCombo;
import com.service.admin.product.controller.rep.HashRateComboPageRep;
import com.service.admin.product.controller.req.HashRateComboAddReq;
import com.service.admin.product.controller.req.UpdateNumReq;
import com.service.admin.product.controller.req.HashRateComboPageReq;

import java.util.List;

/**
 * 算力套餐表
 *
 * @author xxxx
 * @email xxxx@qq.com
 * @date 2019-11-10 22:06:11
 */
public interface ProductHrComboService extends IService<ProductHrCombo> {

    CommonPageRep<HashRateComboPageRep> page(HashRateComboPageReq pageReq);

    void create(HashRateComboAddReq addReq);

    HashRateComboPageRep detail(Integer detail);

    void modifyCombo(HashRateComboAddReq addReq);

    void updateComboStatus(Integer id, HrComboEnum status);

    void updateComboStatus(Integer id, CommonStatusEnums status);

    void updateStockNum(UpdateNumReq numReq);

    void updateBuyNum(UpdateNumReq numReq);

    void updateMinBuyNum(UpdateNumReq numReq);

    void updateProductStockNum(Integer productId, Integer sellNum);

    List<HashRateComboItemRep> items();
}

